﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="Index.aspx.cs" Inherits="_Default" %>

<%@ Import Namespace="Model" %>
<%@ Import Namespace="System" %>
<%@ Import Namespace="System.Collections.Generic" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Main" runat="Server">
    <div class="layui-col-md3 LeftMan_width">
        <div class="mod-menu">
            <ul class="menu-item">
                <li style="background-color: #8c222c;"><a style="color: white;">书籍分类</a></li>
                <li><a href="LeftMenShow.aspx">教辅 、教材、考试</a></li>
                <li><a href="LeftMenShow.aspx">小说</a></li>
                <li><a href="LeftMenShow.aspx">文学</a></li>
                <li><a href="LeftMenShow.aspx">经济</a></li>
                <li><a href="LeftMenShow.aspx">社科</a></li>
                <li><a href="LeftMenShow.aspx">生活</a></li>
                <li><a href="LeftMenShow.aspx">童书 、 综合</a></li>
                <li><a href="LeftMenShow.aspx">科学</a></li>
                <li><a href="LeftMenShow.aspx">互联网</a></li>
            </ul>
            <div class="menu-cont" style="display: none; top: 241px;">
                <div class="menu-cont-list" style="<!--display: none; -->">
                </div>
                <%
                %>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">中小学辅导</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">教师用书</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">学习考试技巧与指导</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">小学</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">高中</a>
                            </div>
                            <h3><a href="LeftMenShow.aspx">大中专教材教辅</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">教师用书</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">自学教程</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">本科</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">成人教育</a>
                            </div>
                            <h3><a href="LeftMenShow.aspx">考试</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">职称、职业英语考试</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">外语翻译资格考试</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">公务员考试</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">自学考试</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">现代小说</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">世界名著</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">中国古典小说</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">小说合集</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">军事战争小说</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">作品集</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">文学史</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">民间文学</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">文学理论</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">戏剧与曲艺</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">经济基础</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">经济宏观理论</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">经济发展史</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">泡沫经济</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">经济与发展</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">社会科学</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">社会科学史</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">社会行为研究</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">社会现实</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">社会参考</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">食谱</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">健康养生</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">社会现状</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">人际关系处理</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">生活心里学</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">动漫与绘本</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">儿童漫画</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">绘本</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">儿童科幻</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">儿童漫画</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">制作工艺</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">气压技术</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">高能物理</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">生物研究</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">物理史学</a>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="menu-cont-list" style="display: none;">
                    <ul>
                        <li>
                            <h3><a href="LeftMenShow.aspx">语言</a></h3>
                            <div class="menu-list-link">
                                <a href="LeftMenShow.aspx">编程</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">程序员的自我修养</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">c#</a>
                                <span class="long-string">|</span>
                                <a href="LeftMenShow.aspx">vue.js</a>
                            </div>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
    </div>
    <div class="layui-col-md9">
        <div class="layui-row">
            <div class="layui-col-md12">
                <!--图片轮播-->
                <div class="layui-carousel" id="test1">
                    <div carousel-item>
                        <%
                            for (var i = 0; i < 5; i++)
                            {
                                Response.Write("<div style='background-image:url(image/Bar" + i + ".jpg);background-size:contain'></div>");
                            }
                        %>
                    </div>
                </div>
            </div>
        </div>
        <!--显示图书-->
        <%
            List<Books>[] list = new List<Books>[3]{
                    newlist,goodlist,kinglist
                };
            string[] title = new string[] { "新书广场", "好书推荐", "教辅王牌" };
            int count = 1;
            for (var i = 0; i < 3; i++)
            {
                Response.Write("<div class='layui-col-md12'>" +
                    "<div class='layui-col-md4'><font style='color: black; font-size: 20px; font-family: '楷体';'>" + title[i] + "</font>/<a href='' style='color: #007DDB;'>更多</a></div>" +
                    " <hr class='layui-bg-black'></div>");
                Response.Write("<div class='layui-col-md12'>");
                if (list[i] != null)
                {
                    foreach (var item in list[i])
                    {
                        string url = @"Bimage/"+count+".jpg";
                        Response.Write("<div class='layui-col-md3'>");
                        Response.Write("<ul>");
                        Response.Write("<li id='"+item.BookID+"'>");
                        Response.Write("<a href='BookDetail.aspx?BookID="+item.BookID+"&BookName="+item.BookName+"&BookAuthor="+item.Author+"&BookPrice="+item.Price+"&BookImageId="+count+"'>");
                        Response.Write("<div style='background-image:url("+url+");background-size: contain; height: 138px; width:100px;' /></div>");
                        Response.Write("</a>");
                        Response.Write("</li>");
                        Response.Write("<li><label>" + item.BookName + "</label></li>");
                        Response.Write("<li><label>" + item.Author + "</label></li>");
                        Response.Write("<li><label>￥"+item.Price+"</label></li></ul></div>");
                        count++;
                    }
                }
            }
            count = 1;
        %>
        </div>
    </div>
</asp:Content>

